From d48232a5fb98f1cc87f9e697ee65b26b0d5237f2 Mon Sep 17 00:00:00 2001 From: "kaf24@scramble.cl.cam.ac.uk" Date: Fri, 16 May 2003 14:54:02 +0000 Subject: [PATCH] bitkeeper revision 1.239 (3ec4fb8aMeMTm7_6dfdrGcBeicV-AQ) kernel.c: Another minor cleanup of the console UDP code. --- xen/common/kernel.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/common/kernel.c b/xen/common/kernel.c index 8495d8b75e..3c92324ca1 100644 --- a/xen/common/kernel.c +++ b/xen/common/kernel.c @@ -574,7 +574,7 @@ long do_console_write(char *str, unsigned int count) { #define SIZEOF_BUF 256 unsigned char safe_str[SIZEOF_BUF]; - unsigned char exported_str[SIZEOF_BUF]; + unsigned char exported_str[SIZEOF_BUF+1]; unsigned char dom_id[5]; unsigned long flags; int i=0; @@ -605,8 +605,8 @@ long do_console_write(char *str, unsigned int count) spin_unlock_irqrestore(&console_lock, flags); - exported_str[j]='\0'; - console_export(exported_str, j-1); + exported_str[j++]='\0'; + console_export(exported_str, j); return(0); } -- 2.30.2